#pragma once
#include <functional>
#include "Log.hpp"

using namespace LogModule;

void Download()
{
    LOG(LogLevel::INFO)<<"我是一个下载的任务...";
    // std::cout << "我是一个下载的任务" << std::endl;
}

class Task
{
public:
    Task() : _func(Download)
    {
    }
    void operator()()
    {
        _func();
    }

private:
    std::function<void()> _func;
};
